]> dgit.raspbian.org Git - gnome-shell.git/commit
windowPreview: Ensure style as soon as preview is realized
authorJonas Dreßler <verdre@v0yd.nl>
Mon, 6 Jul 2020 13:44:25 +0000 (15:44 +0200)
committerFlorian Müllner <fmuellner@gnome.org>
Mon, 6 Jul 2020 21:16:15 +0000 (23:16 +0200)
commitc26860dcb7da9fd51a5dced984c34024664f770e
treea138b0e267f7f042da28cfe46432bfb6100caae9
parent6757c7d20ac09003ea87bc02d2e93605599d8684
windowPreview: Ensure style as soon as preview is realized

For the windowPreview we need to ensure the style information of the
border and title is up-to-date when chromeWidths() or chromeHeights() is
called. Since the introduction of the WorkspaceLayout those functions
may be called during an allocation cycle, which means we should avoid
calling queuing relayouts inside them. Calling StWidgets ensure_style()
method will queue a relayout though in case the newly generated theme
node has a different geometry.

So avoid queueing a relayout during allocation cycles (and the warning
Clutter logs because of that) by ensuring the style of the border and
title earlier, as soon as the WindowPreview is attached to a stage.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1305
js/ui/windowPreview.js